module counter(clk, rstN, out);

input clk;
input rstN;
output reg[1:0] out;

always @(posedge clk or negedge rstN) begin
    if (~rstN) begin
        out <= 2'b00;
    end else begin
        out <= out + 1'b1;
    end
end

endmodule
